﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using DataLayer;
using System.ServiceModel.Activation;

namespace WebServiceBingMaps
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "DataService" in code, svc and config file together.

    [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
    public class DataService : IDataService
    {

        public List<MapPointDTO> GetSchools(decimal topleftlatitude, decimal topleftlongitude, decimal bottomrightlatitude, decimal bottomrightlongitude, int schooltypeid = 0)
        {
            var service = new SchoolService();
            return service.GetSchools(topleftlatitude, topleftlongitude, bottomrightlatitude, bottomrightlongitude, schooltypeid);
        }

        public SchoolDTO GetSchool(int schoolid)
        {
            var service = new SchoolService();
            return service.GetSchool(schoolid);
        }
    }
}
